﻿using System;
using System.Collections.Generic;
using System.Globalization;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Data;
using PPT = Microsoft.Office.Interop.PowerPoint;

namespace An_Im.Converter
{
    internal class AnimEffectNameConverter : IValueConverter
    {
        public object Convert(object value, Type targetType, object parameter, CultureInfo culture)
        {
            if (value is PPT.Effect)
            {
                var eff = value as PPT.Effect;
                var nativeEff = AnimEffect.GetNativeAnimEffect(eff);
                if (nativeEff != null) return string.Format("{0}: {1}", eff.DisplayName, nativeEff.ReplacedName);
            }
            return string.Empty;
        }



        public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture)
        {
            throw new NotImplementedException();
        }
    }
}
